Apparatus, system, and method for sorting character representations of data

ABSTRACT

An apparatus, system, and method are disclosed for sorting character representations of data under the present invention, a character-encoded sort data value is identified in a data line of a data set. The sort data value is a character encoding of a predefined numbering system such as hexadecimal or binary encoding. The sort data value is then converted to a predefined encoding scheme and the data set is sorted based on the converted sort data value. A cycle number may be appended to the sort data value to maintain the order of the sort data values when the sort data values wrap. One embodiment identifies and removes delimiters such as titles from the data set and are inserted into the sorted data set.

BACKGROUND OF THE INVENTION

1. Field of the Invention

This invention relates to sorting data and more particularly relates tosorting character representations of numeric data.

2. Description of the Related Art

Data sets often include an encoding scheme other than a characterencoding scheme that may be displayed in a form easily recognized by auser. For example, a data set may include a predefined numbering systemsuch as a hexadecimal number system and a binary number system. The useroften converts data in the predefined numbering system to a characterrepresentation for analysis. Data sets may include database records, logrecords, trace records, and system dump records. Numeric data values ofthe data set are frequently converted to a character representation byformatting tools to improve readability. Typically, the data set ispresented to a user in a series of data lines. Formatting toolsgenerally sort the data lines using raw data (data not converted to acharacter representation) for one or more data values and add delimiterinformation including titles, page headers, page footers, and the like.

Unfortunately, if a user requires that the data lines of a data set besorted in an alternate manner or using an alternate data value as a sorthandle, the data lines often do not sort correctly because the characterrepresentations of the data values are not ordered the same as the datain the original number system. For example, the character representationof the hexadecimal value ‘F9 ’x (249) is ‘F9’. To sort this data, thehexadecimal value for the character representation is sorted on thecomputer. In one example using the Extended Binary Coded DecimalInterchange Code (EBCDIC) character set, the value ‘C6F9’x represents‘F9.’ So, the computer sorts using the value ‘C6F9’x for ‘F9’x (249).Similarly, ‘C6C1’x is used to sort the character representation ‘FA’(250) of hexadecimal value ‘FA’x. Thus, although ‘F9’ should precede‘FA’ in an ascending sort, ‘FA’ will in fact precede ‘F9’ because‘C6C1’x precedes ‘C6F9’x. In addition, titles, page headers, and pagefooters can also be sorted into arbitrary and useless positions in thedata set.

FIG. 1 illustrates a conventional presorted data set 100. A formattingtool has added a title 120, and one or more page headers 140 to aplurality of data lines 150. Generally, the formatting tool sorts thedata lines 150 according to some fixed sort criteria. Each data line 150includes at least one data value 160 that may be selected as a sort datavalue 160 and may also contain at least one data value 170 that is notselected as a sort data value.

In a hypothetical situation, the sort data value 160 is a characterrepresentation of hexadecimal data. Also the sort data values 110 wraparound from a large value of a set of sequentially ordered values toresume sequential ordering with sort data values 130 from near thebeginning of the set of sequentially ordered values. In other words, thesort data value 160 has a fixed number of digits. Consequently, as thesequence numbers of the sort data value 160 exceed the highest valuethat can be represented with the fixed number of digits, the value inthe sort data value wraps back to all zeros for each digit. Thiswrapping is easily conceptualized using a conventional odometer as anexample. Once all places on the odometer reach a 9 digit, the odometerwraps to all zeros.

The numerically larger sort data values 110 are referred to herein aspre-wrap sort data values 110 and the numerically smaller sort datavalues 130 subsequent to the wrap are referred to herein as post-wrapsort data values 130. Although the pre-wrap sort data values 110 arenumerically larger than the post-wrap sort data values 130, the pre-wrapsort data values 110 represent data values that occur sequentiallybefore the post-wrap sort data values 130. The data values of thepre-wrap sort data values 110 reach a maximum value and wrap to resumesequencing at the lower numeric values of the post-wrap sort data values130.

FIG. 2 illustrates a sorted data set 200. In the depicted sorted dataset 200, a user has sorted the presorted data set 100 of FIG. 1 by thesort data value 160. The sort data values 220, 260 containing thecharacter representations of the hexadecimal digits A-F incorrectly sortahead of the sort data 240, 280 containing the character representationsof hexadecimal digits 0-9. The post-wrap sort data values 130 precedethe pre-wrap sort data values 110, although as explained in FIG. 1, thepre-wrap sort data values 110 sequentially should come before thepost-wrap sort data values 130 in precedence. Although the user mightprefer to retain the title 120 and pager headers 140 in the positionseach occupied relative to the beginning of the report and the beginningof each page, the title 120 and the page headers 140 are grouped at thebeginning of the data set. Thus, the data lines 150 of the sorted dataset 200 are not sorted properly.

From the foregoing discussion, it should be apparent that a need existsfor an apparatus, system, and method that sort character representationsof sort data values in data sets consistent with the original numericencoding. The apparatus, system, and method should retain the originalformatting including properly placed delimiters of the presorted datasets. In addition, there exists a need for an apparatus, system, andmethod that sorts pre-wrap and post-wrap data values.

SUMMARY OF THE INVENTION

The present invention has been developed in response to the presentstate of the art, and in particular, in response to the problems andneeds in the art that have not yet been fully solved by currentlyavailable data set sorting methods. Accordingly, the present inventionhas been developed to provide an apparatus, system, and method forsorting character representations of numeric data that overcome many orall of the above-discussed shortcomings in the art.

The apparatus for sorting character representations of data is providedwith a logic unit containing a plurality of modules configured tofunctionally execute the steps of sorting data. These modules in thedescribed embodiments include an identity module, a conversion module,and a sort module.

The identity module identifies a character-encoded sort data value in aplurality of data lines of a data set. The data set may include databaserecords, log records, trace records, system dump records, or the like.The sort data value comprises a character representation of numeric dataof a predefined numbering system encoded according to a predefinedcharacter set. The predefined numbering system is a number system havinga certain number base (i.e., binary, hexadecimal, octal, etc.) The sortdata value may be automatically detected. Alternatively, a userdesignates the sort data value in the data line.

The conversion module converts the sort data value from the characterrepresentation to a numeric representation according to a predefinedencoding scheme. Preferably, the predefined encoding scheme is theoriginal predefined encoding scheme of the data in the sort data valueused to generate the character representation. In an alternateembodiment, the conversion module converts the sort data value to apredefined encoding scheme other than the original predefined encodingscheme. The sort module sorts the data lines of the data set using theconverted sort data value.

A system of the present invention is also presented to sort characterrepresentations of data. The system may be embodied as a data processingsystem. In particular, the system, in one embodiment, includes a memory,a processor, and an output device. The processor comprises an identitymodule, a conversion module, and a sort module. The identity moduleidentifies a character-encoded sort data value in a plurality of datalines of a data set. In addition, the conversion module converts thesort data value from a character representation to a predefined encodingscheme and stores the converted data of the sort data value in anidentity data value. The identity data value is temporarily appended toeach data line. The sort module sorts the data lines by the identitydata value. The identity data value may be discarded after the sort. Thesort module may render the sorted data set on the output device. Theoutput device may be a printer, a display, or the like.

A method of the present invention is also presented for sortingcharacter representations of data. The method in the disclosedembodiments substantially includes the steps necessary to carry out thefunctions presented above with respect to the operation of the describedapparatus and system. The identity module identifies a character-encodedsort data value in a data set. The conversion module converts the sortdata value to a predefined encoding scheme. The sort data value mayoriginally be a fixed-digit data value of a predefined numbering systemsuch as hexadecimal numbering.

In one embodiment, the conversion module appends a cycle number to thesort data value as the most significant value of the to the sort datavalue. The cycle number functions as the most significant value of thesort data value and differentiates pre-wrap sort data values andpost-wrap sort data values during a sort. The cycle number may be usedto order sort data values occurring prior to and subsequent to a wrap ofsort data values. Thus the first sort data value would be sorted aspreceding the second sort data value. The method may assign the cyclenumber an initial value.

In one embodiment, the method calculates an absolute value of thedifference between a first data value for a first sort data value of afirst data line and a second data value of a second data line. Theconversion module may increment the cycle number by an increment valueif the first sort data value exceeds the second sort data value and ifthe absolute value of the difference exceeds a next-wrap threshold. Inone embodiment, the conversion module decrements the cycle number by theincrement value if the second sort data value exceeds the first sortdata value and the absolute value of the difference exceeds a pre-wrapthreshold.

In one embodiment, the sort module identifies a delimiter and adelimiter offset. The delimiter may be a title, a page header, and apage footer. The delimiter offset may be the delimiter's relativelocation in a rendered data set. For example, the title may be the firstline in the data set and the delimiter offset of the title may be zero(0) from the beginning of the data set. The sort module may remove thetitle from the data set. Then the sort module sorts the data set andre-inserted the delimiter in the data set using the delimiter offset inthe sorted data set. For example, the title may be re-inserted in thedata set with the offset of zero (0) from the beginning of the data set.

Reference throughout this specification to features, advantages, orsimilar language does not imply that all of the features and advantagesthat may be realized with the present invention should be or are in anysingle embodiment of the invention. Rather, language referring to thefeatures and advantages is understood to mean that a specific feature,advantage, or characteristic described in connection with an embodimentis included in at least one embodiment of the present invention. Thus,discussion of the features and advantages, and similar language,throughout this specification may, but do not necessarily, refer to thesame embodiment.

Furthermore, the described features, advantages, and characteristics ofthe invention may be combined in any suitable manner in one or moreembodiments. One skilled in the relevant art will recognize that theinvention can be practiced without one or more of the specific featuresor advantages of a particular embodiment. In other instances, additionalfeatures and advantages may be recognized in certain embodiments thatmay not be present in all embodiments of the invention.

The apparatus, system, and method sorts character representations ofnumerical data in a data set as converted sort data values and retainsthe original formatting including properly placed delimiters of thepresorted data set. In addition, the apparatus, system, and method sortpre-wrap and post-wrap sort data values including intermingled pre-wrapand post-wrap sort data values. These features and advantages willbecome more fully apparent from the following description and appendedclaims, or may be learned by the practice of the invention as set forthhereinafter.

BRIEF DESCRIPTION OF THE DRAWINGS

In order that the advantages of the invention will be readilyunderstood, a more particular description of the invention brieflydescribed above will be rendered by reference to specific embodimentsthat are illustrated in the appended drawings. Understanding that thesedrawings depict only typical embodiments of the invention and are nottherefore to be considered to be limiting of its scope, the inventionwill be described and explained with additional specificity and detailthrough the use of the accompanying drawings, in which:

FIG. 1 is a representation of data set sorted according to fixed sortcriteria;

FIG. 2 is a representation of data set sorted by a character-encodedrepresentation of numeric data;

FIG. 3 is a block diagram illustrating one embodiment of a sortingsystem in accordance with the present invention;

FIG. 4 is a block diagram illustrating one embodiment of a sortingapparatus of the present invention;

FIG. 5 is a flow chart diagram illustrating one embodiment of a sortingmethod in accordance with the present invention;

FIG. 6 is a flow chart diagram illustrating one embodiment of adelimiter relocation method of the present invention; and

FIG. 7 is a representation of one embodiment of data set sorted inaccordance with the present invention.

DETAILED DESCRIPTION OF THE INVENTION

Many of the functional units described in this specification have beenlabeled as modules, in order to more particularly emphasize theirimplementation independence. For example, a module may be implemented asa hardware circuit comprising custom VLSI circuits or gate arrays,off-the-shelf semiconductors such as logic chips, transistors, or otherdiscrete components. A module may also be implemented in programmablehardware devices such as data value programmable gate arrays,programmable array logic, programmable logic devices or the like.

Modules may also be implemented in software for execution by varioustypes of processors. An identified module of executable code may, forinstance, comprise one or more physical or logical blocks of computerinstructions, which may, for instance, be organized as an object,procedure, or function. Nevertheless, the executables of an identifiedmodule need not be physically located together, but may comprisedisparate instructions stored in different locations which, when joinedlogically together, comprise the module and achieve the stated purposefor the module.

Indeed, a module of executable code could be a single instruction, ormany instructions, and may even be distributed over several differentcode segments, among different programs, and across several memorydevices. Similarly, operational data may be identified and illustratedherein within modules, and may be embodied in any suitable form andorganized within any suitable type of data structure. The operationaldata may be collected as a single data set, or may be distributed overdifferent locations including over different storage devices, and mayexist, at least partially, merely as electronic signals on a system ornetwork.

Reference throughout this specification to “one embodiment,” “anembodiment,” or similar language means that a particular feature,structure, or characteristic described in connection with the embodimentis included in at least one embodiment of the present invention. Thus,appearances of the phrases “in one embodiment,” “in an embodiment,” andsimilar language throughout this specification may, but do notnecessarily, all refer to the same embodiment.

Furthermore, the described features, structures, or characteristics ofthe invention may be combined in any suitable manner in one or moreembodiments. In the following description, numerous specific details areprovided, such as examples of programming, software modules, userselections, network transactions, database queries, database structures,hardware modules, hardware circuits, hardware chips, etc., to provide athorough understanding of embodiments of the invention. One skilled inthe relevant art will recognize, however, that the invention can bepracticed without one or more of the specific details, or with othermethods, components, materials, and so forth. In other instances,well-known structures, materials, or operations are not shown ordescribed in detail to avoid obscuring aspects of the invention.

FIG. 3 illustrates one embodiment of a sorting system 300 of the presentinvention. The sorting system 300 is adapted to sort data sets includinga data set that was originally numerically encoded such as databaserecords, log records, trace records, system dump records, and the like.A user may subsequently convert the numeric data to a character encodingas part of a report for ease of viewing and analysis. Certain numericdata such as hexadecimal numbers may be converted to charactersrepresenting the same hexadecimal digits. So ‘9’x is represented by thecharacter ‘9.’ The report may include titles, pager header, pagerfooters and other delimiters. In addition, the data set may be stored inthe character-encoded form.

The user may desire to sort the data set subsequent to the data set'sconversion to the character-encoded format. However, some of theconverted sort data values may sort differently as a character encodedrepresentation than in the sort data values' original encoding scheme.For example, when the hexadecimal numbers ‘A’x (10) through ‘F’x (15)are encoded in Extended Binary Coded Decimal Interchange Code (EBCDIC),the character encoded representation of the hexadecimal number ‘A’xthrough ‘F’x have precedence in an ascending sort over the characterencoded representations of the hexadecimal numbers ‘0’x through ‘9’x.Typically this is due to character set used to convert between numericdata and character representations. Thus sorting the data set by thecharacter encoded sort data values incorrectly sorts the data lines ofthe data set relative to the original encoding scheme of the sort datavalues.

The sorting system 300 as depicted includes a memory 320, a processor310 and an output device 360. The processor 310 comprises an identitymodule 330, a conversion module 340, and a sort module 350. The outputdevice 360 may comprise a printer, a monitor, or the like. The identitymodule 330 identifies a character-encoded sort data value in a pluralityof data lines of the data set. Each data line of the data set includesthe sort data value. The sort data value may function as a sort handle,the data value associated with a group of data such as a data line. Byordering the sort data value, each data line in a data set may beordered. For example, the data sort value may be a time value. Bysorting the time values, the data associated with each time value isordered in chronological order.

The sort data value comprises a character representation of numeric dataof a predefined numbering system. The character representation isderived using a predefined character set such as Extended Binary CodedDecimal Interchange Code (EBCDIC). In one embodiment, the predefinednumbering system is hexadecimal encoding. In an alternate embodiment,the predefined encoding scheme is binary encoding.

A user may designate a sort data value to the identity module 330 usinga parameter or user interface. The identity module 330 identifies thesort data value and the conversion module 340 converts the sort datavalue from a character representation to a predefined encoding schemeaccording to the predefined character set. In one embodiment, theconversion module 340 stores the converted sort data value in anidentity data value. The identity data value may be a temporary datavalue that is used to sort the data lines of the data set. The identitydata value may be modified without modifying the source sort data value.In a certain embodiment, the identity data value is appended to eachdata line. The sort module 350 sorts the data lines of the data set bythe identity data value. Once sorted, the identity data values may bediscarded.

The processor 310 may render the sorted data set using the output device360. In one embodiment, the conversion module 340 converts the sort datavalue back to the predefined character set and renders the originalcharacter representation of the sort data value. The sorting system 300allows the sorting of data sets according to character-encoded numericdata values.

FIG. 4 is a block diagram illustrating one embodiment of a sortingapparatus 400 of the present invention. The sorting apparatus 400 sortsa data set and includes an identity module 330, a conversion module 340,and a sort module 350. The identity module 330 identifies acharacter-encoded sort data value for each data line of the data set. Inone embodiment, the user provides one or more parameters specifying thelocation of the sort data value in the data line.

The conversion module 340 converts the sort data value from thecharacter representation to a predefined encoding scheme. Preferably,the predefined encoding scheme is the original predefined encodingscheme of the data in the sort data value used to generate the characterrepresentation. In an alternate embodiment, the conversion module 340converts the sort data value to a predefined encoding scheme other thanthe original predefined encoding scheme.

For example, the original sort data values may be encoded in ashexadecimal numbers prior to conversion to character encoding such asEBCDIC. The conversion module 340 may convert the character encoded sortdata values to an alternate predefined encoding scheme, such as decimalnumbering. In one embodiment, the user selects the predefined encodingscheme.

The sort module 350 sorts the data lines of the data set by theconverted sort data value. In one embodiment, the sort module 350 sortsthe sort data values in ascending order. For example, ‘7’ is sortedbefore ‘8’ in an ascending sort order. In an alternate embodiment, thesort module 350 sorts the sort data values in descending value. Forexample, ‘4’ is sorted before ‘2’ in a descending sort order.

The sorting apparatus 400 sorts character-encoded sort data values byconverting the character-encoded sort data values to a predefinedencoding scheme such as hexadecimal numbers. The sort data values may besorted to order the character-encoded sort data values in accordancewith the original numeric numbering system of the sort data values. Thusin one embodiment, the hexadecimal ‘9’x (9) would have precedence overthe hexadecimal ‘A’x (10), although the EDCDIC representation of ‘A’x(10) had precedence over the EDCDIC representation of ‘9’x (9) in thedata set.

The schematic flow chart diagrams that follow are generally set forth aslogical flow chart diagrams. As such, the depicted order and labeledsteps are indicative of one embodiment of the presented method. Othersteps and methods may be conceived that are equivalent in function,logic, or effect to one or more steps, or portions thereof, of theillustrated method. Additionally, the format and symbology employed areprovided to explain the logical steps of the method and are understoodnot to limit the scope of the method. Although various arrow types andline types may be employed in the flow chart diagrams, they areunderstood not to limit the scope of the corresponding method. Indeed,some arrows or other connectors may be used to indicate only the logicalflow of the method. For instance, an arrow may indicate a waiting ormonitoring period of unspecified duration between enumerated steps ofthe depicted method. Additionally, the order in which a particularmethod occurs may or may not strictly adhere to the order of thecorresponding steps shown.

FIG. 5 is a schematic flow chart diagram illustrating one embodiment ofa sorting method 500 of the present invention. The identity module 330identifies 520 a character-encoded sort data value in a data set.Typically, the sort data value comprises a field or column in each dataline of a data set. In one embodiment, a user specifies the sort datavalue. The conversion module 340 converts 540 the sort data value to apredefined encoding scheme. The converted sort data value may be afixed-digit sequential data value.

In one embodiment, the conversion module 340 appends 560 a cycle numberto the sort data value. The conversion module 340 appends 560 the cyclenumber as the most significant value of the sort data value. Mostsignificant value as used herein refers to one or more most significantdigits. The conversion module 340 appends 560 the cycle number to ordersort data values when one or more sort data values have wrapped. Datavalues with fixed numbers of digits may wrap when a data value in theset of sequential data values reaches a maximum value. Thus in a set oftwo digit data values the data value ‘99’ may be followed by the datavalue ‘00’ as the data values wrap to the beginning of the sequentialorder to accommodate ordering data values beyond the range of theavailable digits. The data value ‘99’ should have precedence over thesubsequent ‘00’, although in a regular ascending sort that does notaccommodate wrapping, ‘00’would have precedence over ‘99’

The cycle number functions as a most significant value that can be usedto differentiate pre-wrap sort data values and post-wrap sort datavalues during a sort. For example, if a first hexadecimal sort datavalue ‘FF’x (255) is followed by a second hexadecimal sort data value‘00’x (00) where the second sort data value occurred after a wrap of thesequence of sort data values from ‘FF’x to ‘00’x (00), the conversionmodule 340 may append ‘00’x (00) to the first sort data value to form‘00FF’x (255) and append ‘01’x (01) to the second sort data value toform ‘0100’ (256). Thus the first sort data value would sort before thesecond sort data value because the cycle number is included in thesorting of the sort data value. The conversion module 340 may incrementthe cycle number by an increment value each time the sort data valueswrap. In one embodiment, the increment value is one.

In addition to pre-wrap and post-wrap sort data values occurringsequentially, pre-wrap and post-wrap sort data values may beintermingled. In one embodiment, the conversion module 340 modifies thecycle number to differentiate intermingled pre-wrap sort data values andpost-wrap sort data values. To modify the cycle number, the conversionmodule 340 may calculate the absolute value of the difference between afirst data value of a first sort data line and a second sort data valueof a second data line. The absolute value of the difference is used tomodify the cycle number to adjust for the wrapping of data sort values.

In one embodiment, the conversion module 340 increments the cycle numberby the increment value if the first data value exceeds the second datavalue and if the difference exceeds a next-wrap threshold. The next-wrapthreshold is a predefined data value selected to identify pre-wrap andpost-wrap data values in a set of data values. For example, in theordered set of data values ‘F8’x (248), ‘F1’x (241), ‘02’x (02), and‘FA’x (250) each element of the set is assumed to be grouped inapproximately a sequential order although with some deviation to thesequential order. Thus the relative positions of a first element of thedata set provides information on the first element's position relativeto other elements, although the first element may not be in preciselysequential order relative to the other elements.

In the example above, ‘02’x (02) may be assumed to be grouped near to‘F1 ’x (241) and ‘FA’x (250) because ‘02’x (02) shares approximately theordered position of ‘F1’x (241) and ‘FA’x (250) instead of ‘02’x (02)having an ordered position far removed from ‘F1’x (241) and ‘FA’x (250).In the exemplary data set above, ‘F1’x (241) is the first sort datavalue and ‘02’x (02) is the second sort data value. The conversionmodule 340 uses pre-wrap and post-wrap thresholds to identify sort datavalues that should be grouped in sequential proximity to logicallyadjacent sort data values such as ‘F1 ’x (241) and ‘02’x (02) but thatappear to be sequentially distant because of the wrapping of the sortdata value digits. In addition, the data set may have been sorted by analternate sort data value, intermingling sort data values.

For example, the pre-wrap and post-wrap thresholds may be “10”x (16),the cycle number may be ‘00’x (00), and the increment value may be ‘01’x(01) for the exemplary data set. Thus the absolute value of thedifference between ‘F1 ’x (241) and ‘02’x (02) is ‘EF’x (239). Becausethe absolute value of the difference ‘EF’x (239) exceeds the next-wrapthreshold of ‘10’x (16) and the first data value ‘F1 ’x (241) exceedsthe second data value ‘02’x (02), the conversion module 340 incrementsthe cycle number ‘00’x (00) to ‘01’x (01) and appends 560 theincremented cycle number ‘01’x (01) to the second sort data value ‘02’x(02) so that the appended second data value ‘0102’x (258) will beordered subsequent to the sort data value of the appended first datavalue ‘00F1 ’x (241). Thus the second sort data value ‘02’x (02) thatappears to precede the first sort data value ‘F1’x (241) because thesecond sort data value ‘02’x (02) wrapped will be sorted subsequent tothe first sort data value ‘00F1 ’ x (241).

In one embodiment, the conversion module 340 decrements the cycle numberby the increment value if the second data value exceeds the first datavalue and the difference exceeds a pre-wrap threshold. In the exampleusing hexadecimal numbers of the exemplary data set, the first datavalue is ‘02’x , (02), the second data value is ‘FA’x (250), the cyclenumber is ‘01’x (01), and the pre-wrap and post-wrap threshold is ‘10’x(16). In addition, the appended first sort datavalue is ‘0102’x (258) ascalculated previously. The absolute value of the difference between thefirst data value ‘02’x, (02) and the second data value ‘FA’x (250) is‘F8’x (248) and exceeds the pre-wrap threshold ‘10’x (16).

The conversion module 340 may determine that the second data value ‘FA’x(250) should be ordered prior to the first data value because the seconddata value exceeds the first data value, and because the absolute valueof the difference exceeds the post-wrap threshold. Thus the conversionmodule 340 decrements the cycle number by the increment value of ‘01’x(01) so that the cycle number is ‘00’x (00). In addition, the conversionmodule 340 appends 560 the cycle number to the second data value, thesecond data value becoming ‘00FA’x (250). Thus the appended first sortdata value ‘0102’x is preceded by the appended second data sort value‘00FA’x (250) when sorted. The conversion module 340 identifies sortdata values that are in sequential proximity but that appearsequentially distant and adjusts the cycle number appended 560 to thesort data values so that the appended sort data values sort to theproper sequence.

The sort module 350 sorts 580 the data lines of the data set by theconverted data value in the sort data value. In one embodiment, theconverted sort data value is the appended sort data value. For example,using the previous exemplary data set, the sort module 350 sorts 580 thesort data value ‘02’x (02) as ‘0102’x (258). In one embodiment, the sortmodule 350 renders 590 the sorted data set. In a certain embodiment, thesort module 350 may render 590 each sort data value with the appendedcycle number. The sort module 350 may also render 590 each sort datavalue without the appended cycle number. The sorting method 500 sorts acharacter-encoded data set using a converted sort data value as the sorthandle.

FIG. 6 is a schematic flow chart diagram illustrating one embodiment ofa delimiter relocation method 600 of the present invention. Thedelimiter relocation method 600 may be included in the sorting method500 illustrated in FIG. 5. The sort module 350 identifies 620 adelimiter and a delimiter offset. The delimiter may be a title, a pageheader, and a page footer. The delimiter offset may be the delimiter'srelative location in a rendered data set from the beginning of the dataset or from another reference point. For example, the title may be thefirst line in the data set and have a delimiter offset of zero (0) fromthe beginning of the data set, the page header may be first line of arendered data set page and have a delimiter offset of zero (0) from apage break, and the page footer may be the fiftieth line of the rendereddata set page and have a delimiter offset of forty-nine (49) from thepage break. In one embodiment, a user supplies a delimiter identifier tothe sort module 350. For example, the delimiter identifier may be textcommon to one or more delimiters such as the text word “Page.” The sortmodule 350 may scan a data line for the text word “Page.” If “Page” isnot found, the data line is a data line with a delimiter. In oneembodiment, the scan module 350 scans the data set once for eachdelimiter identifier. The sort module 350 may identify 620 a delimitersuch as the character encoded text line “System Log Page 4” using thedelimiter identifier “Page.”

The sort module 350 removes 640 the delimiter from the character-encodeddata set. In one embodiment, sort module 350 stores the delimiter andthe delimiter offset. The sort module 350 then sorts 650 the data set.In one embodiment, the sort module 350 sorts the data set using thesorting method 500 of FIG. 5. The sort module 350 inserts 660 thedelimiter in the sorted data set using the delimiter offset. Forexample, the sort module 350 may insert 660 the title as the first linein the rendered sorted data set with a delimiter offset of zero (0) fromthe beginning of the data set, the page header as the first line in arendered sorted data set page with a delimiter offset of zero (0) fromthe page break, and the page footer as the last line of the renderedsorted data set page with a delimiter offset of forty-nine (49). Thesort module 350 removes 640 delimiters from a data set and reinserts 660the delimiters in the sorted data set such that the delimiters provideuseful information.

FIG. 7 is a schematic flow chart diagram illustrating one embodiment ofsorted data set 700 of the present invention. The depicted sorted dataset 700 represents the presorted data set 100 depicted in FIG. 1subsequent to the application of the sorting method 500 illustrated inFIG. 5.

The sorted data set 700 includes delimiters such as the title 120 andthe page header 140 located in appropriate positions. Referring to theleast significant hexadecimal value in the sort data values, the sortdata values 720 with the digits 0-9 precede the sort data values 740with the digits A-F. The pre-warp sort data values 110 also precede thepost-wrap sort data values 130 although the hexadecimal values of thepost-wrap sort data values 130 are greater than the hexadecimal valuesof the pre-wrap sort data values 110.

The present invention sorts character representations of numerical datain data sets as converted sort data values 720, 740 and retains theoriginal formatting including properly placed delimiters of thepresorted data set. In addition, the present invention sorts pre-wrapand post-wrap sort data values 110, 130 including intermingled pre-wrapsort data values 110 and post-wrap sort data values 130. For example,‘FE’760 is before ‘01’ 780, although in an ascending sort ‘01’780 wouldcome before ‘FE’760.

The present invention may be embodied in other specific forms withoutdeparting from its spirit or essential characteristics. The describedembodiments are to be considered in all respects only as illustrativeand not restrictive. The scope of the invention is, therefore, indicatedby the appended claims rather than by the foregoing description. Allchanges which come within the meaning and range of equivalency of theclaims are to be embraced within their scope.

1. An apparatus to sort character representations of data, the apparatuscomprising: an identity module configured to identify character-encodedsort data values in a plurality of data lines of a data set, the sortdata values comprising a character representation of data encodedaccording to a predefined character set; a conversion module configuredto convert the sort data values from the character representation to apredefined encoding scheme; and a sort module configured to sort thedata lines using the converted sort data.
 2. The apparatus of claim 1,wherein the sort data values comprise fixed-digit sequential data andwherein the conversion module appends a cycle number to the sort datavalue as a most significant value, the cycle number representative of asubsequent set of sequential data for which the value is greater thansequential data within a previous set of sequential data, the sets ofsequential data defined by the fixed-digit size of the sort data value.3. The apparatus of claim 2, wherein the conversion module is furtherconfigured to calculate an absolute value of the difference between afirst sort data value of a first data line and a second sort data valueof a second data line and to increment the cycle number of the secondsort data value by an increment value in response to the first sort datavalue exceeding the second sort data value and the absolute value of thedifference exceeding a next-wrap threshold and to further decrement thecycle number of the second sort data value by the increment value inresponse to the second sort data value exceeding the first sort datavalue and the difference exceeding a pre-wrap threshold.
 4. Theapparatus of claim 3, wherein the conversion module is furtherconfigured to calculate the pre-wrap threshold and the next-wrapthreshold from the fixed-digit size of the first sort data value.
 5. Theapparatus of claim 1, wherein the character representation is ExtendedBinary Coded Decimal Interchange Code.
 6. The apparatus of claim 1, thesort module further configured to: identify a delimiter and a delimiteroffset; remove the delimiter from the data set; and insert the delimiterinto the sorted data lines in accordance with the delimiter offset. 7.The apparatus of claim 6, wherein the sort module is further configuredto receive delimiter identifiers.
 8. A system to sort characterrepresentations of data, the system comprising: a memory configured tostore and retrieve data; a processor having, an identity moduleconfigured to identify character-encoded sort data values in a pluralityof data lines of a data set, the sort data values comprising a characterrepresentation of data encoded according to a predefined character set;a conversion module configured to convert the sort data values from thecharacter representation to a predefined encoding scheme and store theconverted sort data as an identity data value; a sort module configuredto sort the data lines using the identity data value; and an outputdevice configured to render the sorted data set.
 9. The system of claim8, wherein the identity data value comprises fixed-digit sequential dataand wherein the conversion module appends a cycle number to the identitydata value as a most significant value, the cycle number representativeof a subsequent set of sequential data for which the value is greaterthan sequential data within a previous set of sequential data, the setsof sequential data defined by the fixed-digit size of the identity datavalue.
 10. The system of claim 9, the conversion module furtherconfigured to calculate an absolute value of the difference between afirst identity data value of a first data line and a second identitydata value of a second data line and to increment the cycle number ofthe second identity data value by an increment value in response to thefirst identity data value exceeding the second identity data value andthe absolute value of the difference exceeding a next-wrap threshold andto further decrement the cycle number of the second identity data valueby the increment value in response to the second identity data valueexceeding the first identity data value and the absolute value of thedifference exceeding a pre-wrap threshold.
 11. The system of claim 10,the conversion module further configured to calculate the pre-wrapthreshold and the next-wrap threshold from the fixed-digit size of thefirst identity data value.
 12. The system of claim 11, the sort modulefurther configured to: identify a delimiter and a delimiter offset;remove the delimiter from the data set; and insert the delimiter intothe sorted data lines in accordance with the delimiter offset.
 13. Asignal bearing medium tangibly embodying a program of machine-readableinstructions executable by a digital processing apparatus to performoperations to sort character representations of data, the operationscomprising: identifying a character-encoded sort data value in aplurality of data lines of a data set, the sort data value comprising acharacter representation of data encoded according to a predefinedcharacter set; converting the sort data value from the characterrepresentation to data encoded according to a predefined encodingscheme; and sorting the data lines using the converted sort data value.14. The signal bearing medium of claim 13, wherein the sort data valuecomprises fixed-digit sequential data and wherein the instructionsfurther comprise operations to append a cycle number to the sort datavalue as a most significant value, the cycle number representative of asubsequent set of sequential data for which a value is greater thansequential data within a previous set of sequential data, the sets ofsequential data defined by the fixed-digit size of the sort data value.15. The signal bearing medium of claim 14, wherein the instructionsfurther comprise operations to calculate an absolute value of thedifference between a first sort data value of a first data line and asecond sort data value of a second data line and to increment the cyclenumber of the second sort data value by an increment value in responseto the first sort data value exceeding the second sort data value andthe absolute value of the difference exceeding a next-wrap threshold andto further decrement the cycle number of the second sort data value bythe increment value in response to the second sort data value exceedingthe first sort data value and the absolute value of the differenceexceeding a pre-wrap threshold.
 16. The signal bearing medium of claim15, wherein the instructions further comprise operations to selectivelycalculate the pre-wrap threshold and the next-wrap threshold from thefixed-digit size of the first sort data value.
 17. The signal bearingmedium of claim 13, wherein the predefined encoding scheme is ahexadecimal number system.
 18. The signal bearing medium of claim ofclaim 13, wherein the instructions further comprise operations to:identify a delimiter and a delimiter offset; remove the delimiter fromthe data set; and insert the delimiter into the sorted data lines inaccordance with the delimiter offset.
 19. The signal bearing medium ofclaim 18, wherein the instructions further comprise operations toreceive delimiter identifiers.
 20. The signal bearing medium of claim19, wherein the instructions further comprise operations to prompt auser to confirm a valid delimiter.